package pvn.com.utils;

import java.util.Calendar;
import java.util.Date;
import java.util.TimeZone;

public class DateConverter {
    public static Date Convert(String ticks) {
        long time_temp = Long.parseLong(ticks);
        Date date_temp = new Date();
        TimeZone tz = Calendar.getInstance().getTimeZone();
        date_temp.setTime(time_temp * 1000L - (tz.useDaylightTime() ? 3600000 : 0)
                - tz.getRawOffset());
        return date_temp;
    }
}